package bairui.international.model.type;

/**
 *
 * (图片类型)Type_SpreadImage
 */
@com.lianjing.sh.processing.info.annotation.GenerateInfoModel
@com.lianjing.sh.model.common.annotation.Comment("图片类型")
@com.lianjing.sh.processing.info.annotation.InfoComment("图片类型")
public enum Type_SpreadImage implements com.sh_lianjing.standard.EnumCommentable<Type_SpreadImage> {

	/**
	 * (分享)Share</br>
	 */
	@com.lianjing.sh.model.common.annotation.Comment("分享")
	@com.lianjing.sh.processing.info.annotation.InfoComment("分享")
	Share("分享")
,
	/**
	 * (抵用券)Use</br>
	 */
	@com.lianjing.sh.model.common.annotation.Comment("抵用券")
	@com.lianjing.sh.processing.info.annotation.InfoComment("抵用券")
	Use("抵用券")
,
	/**
	 * (代理区域)Proxy</br>
	 */
	@com.lianjing.sh.model.common.annotation.Comment("代理区域")
	@com.lianjing.sh.processing.info.annotation.InfoComment("代理区域")
	Proxy("代理区域")
;

	private static java.util.Map<String, Type_SpreadImage> Cache = new java.util.HashMap<>();
	static{
		for(Type_SpreadImage enumItem : Type_SpreadImage.values()){
			Cache.put(enumItem.getComment(), enumItem);
		}
	}

	private String comment;

	private Type_SpreadImage(String comment){
		this.comment = comment;
	}

	@Override
	public String toString() {
		return comment;
	}

	@Override
	public String getComment() {
		return comment;
	}

	@Override
	public Type_SpreadImage parseByComment(String comment) {
		return Type_SpreadImage.parse(comment);
	}

	public static Type_SpreadImage parse(String comment) {
		Type_SpreadImage enumItem = Cache.get(comment);
		if(null == enumItem){
			 throw new com.sh_lianjing.standard.exception.EnumCommentableException(Type_SpreadImage.class, comment);
		}
		return enumItem;
	}

}
